<?php require_once('../connections/con_gl.php'); ?>

<?php

$bar = $_GET['barang'];

$kid = $_GET['kid'];

// get kendaraan

mysql_select_db($database_con_gl, $con_gl);

$query_harga = "select a.supir from gl_jenbar a, gl_jkendaraan b, gl_kendaraan c where a.barang='$bar' AND c.nopol='$kid' AND b.id = c.jenis AND b.id = a.jenis";

$harga       = mysql_query($query_harga, $con_gl) or die(mysql_error());

$row_harga   = mysql_fetch_assoc($harga);

$total_harga = mysql_num_rows($harga);

?>
<input name="supir" type="text" id="supir" value="<?php echo $row_harga['supir'];?>" size="10" maxlength="10" onchange="javascript:this.form.biaya.value = (2*this.form.supir.value) - this.form.supir.value + (2*this.form.bbm.value) - this.form.bbm.value + (2*this.form.tol.value) - this.form.tol.value + (2*this.form.parkir.value) - this.form.parkir.value + (2*this.form.akomodasi.value) - this.form.akomodasi.value + (2*this.form.other.value) - this.form.other.value"/>